Methods
StdRegProv has 20 methods:
Method | Description |
---|---|
CheckAccess | Verifies that the user has the specified access permissions. |
CreateKey | Creates a subkey. |
DeleteKey | Deletes a subkey. |
DeleteValue | Deletes a named value. |
EnumKey | Enumerates subkeys. |
EnumValues | Enumerates the named values of a key. |
GetBinaryValue | Gets the binary data value of a named value. |
GetDWORDValue | Gets the DWORD data value of a named value. |
GetExpandedStringValue | Gets the expanded string data value of a named value. |
GetMultiStringValue | Gets the multiple string data values of a named value. |
GetQWORDValue | Gets the QWORD data values of a named value. |
GetSecurityDescriptor | Gets the security descriptor for a key. |
GetStringValue | Gets the string data value of a named value. |
SetBinaryValue | Sets the binary data value of a named value. |
SetDWORDValue | Sets the DWORD data value of a named value. |
SetExpandedStringValue | Sets the expanded string data value of a named value. |
SetMultiStringValue | Sets the multiple string values of a named value. |
SetQWORDValue | Sets the QWORD data values of a named value. |
SetSecurityDescriptor | Sets the security descriptor for a key. |
SetStringValue | Sets the string value of a named value. |
Learn more about Invoke-CimMethod
and how to invoke commands. Click any of the methods listed above to learn more about their purpose, parameters, and return value.
Properties
StdRegProv returns no properties.
CDXML Definition
You can turn this WMI class and its methods into PowerShell cmdlets by importing below CDXML file (Cmdlet Definition XML) as a module.
Create StdRegProv.cdxml
$folder = "c:\wmi\StdRegProv"
$cdxmlPath = Join-Path -Path $folder -ChildPath "StdRegProv.cdxml"
# create folder if not present:
$exists = Test-Path -Path $folder
if (!$exists) { $null = New-Item -Path $folder -ItemType Directory }
# write file
$content = @'
<?xml version="1.0" encoding="utf-8"?>
<!--
This file is licensed under 'Attribution 4.0 International' license (https://creativecommons.org/licenses/by/4.0/).
You can free of charge use this code in commercial and non-commercial code, and you can freely modify and adjust the code
as long as you give appropriate credit to the original author Dr. Tobias Weltner.
This material was published and is maintained here:
https://powershell.one/wmi/root/default, root/cimv2/stdregprov#cdxml-definition
-->
<PowerShellMetadata xmlns="http://schemas.microsoft.com/cmdlets-over-objects/2009/11">
<!--referencing the WMI class this cdxml uses-->
<Class ClassName="Root/default, Root/CIMv2\StdRegProv" ClassVersion="2.0">
<Version>1.0</Version>
<!--default noun used by Get-cmdlets and when no other noun is specified. By convention, we use the prefix "WMI" and the base name of the WMI class involved. This way, you can easily identify the underlying WMI class.-->
<DefaultNoun>WmiStdRegProv</DefaultNoun>
<!--define the cmdlets that work with class instances.-->
<InstanceCmdlets>
<!--query parameters to select instances. This is typically empty for classes that provide only one instance-->
<GetCmdletParameters />
<!--defining additional cmdlets that modifies instance properties-->
</InstanceCmdlets>
<!--define the cmdlets that work with class instances.-->
<StaticCmdlets>
<!--Test-StdRegProvAccess: invoking method CheckAccess():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Test" Noun="WmiStdRegProvAccess" ConfirmImpact="Low" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="CheckAccess">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'string'-->
<Parameter ParameterName="string">
<!--the underlying parameter type is which corresponds to the PowerShell .NET type [system.]-->
<Type PSType="system." />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'uint32'-->
<Parameter ParameterName="uint32">
<!--the underlying parameter type is which corresponds to the PowerShell .NET type [system.]-->
<Type PSType="system." />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--Method returns an instance of bool in property bGranted-->
<Parameter ParameterName="bGranted">
<Type PSType="Microsoft.Management.Infrastructure.CimInstance[]" />
<CmdletOutputMetadata />
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--New-StdRegProvRegistryKey: invoking method CreateKey():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="New" Noun="WmiStdRegProvRegistryKey" ConfirmImpact="Low" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="CreateKey">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'hDefKey'-->
<Parameter ParameterName="hDefKey">
<!--the underlying parameter type is which corresponds to the PowerShell .NET type [system.]-->
<Type PSType="system." />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'sSubKeyName'-->
<Parameter ParameterName="sSubKeyName">
<!--the underlying parameter type is which corresponds to the PowerShell .NET type [system.]-->
<Type PSType="system." />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Remove-StdRegProvRegistryKey: invoking method DeleteKey():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Remove" Noun="WmiStdRegProvRegistryKey" ConfirmImpact="High" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="DeleteKey">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'hDefKey'-->
<Parameter ParameterName="hDefKey">
<!--the underlying parameter type is which corresponds to the PowerShell .NET type [system.]-->
<Type PSType="system." />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'sSubKeyName'-->
<Parameter ParameterName="sSubKeyName">
<!--the underlying parameter type is which corresponds to the PowerShell .NET type [system.]-->
<Type PSType="system." />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Remove-StdRegProvRegistryValue: invoking method DeleteValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Remove" Noun="WmiStdRegProvRegistryValue" ConfirmImpact="High" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="DeleteValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Get-StdRegProvChildKey: invoking method EnumKey():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Get" Noun="WmiStdRegProvChildKey" ConfirmImpact="Low" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="EnumKey">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubkeyName'-->
<Parameter ParameterName="SubkeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--Method returns an instance of string in property sNames-->
<Parameter ParameterName="sNames">
<Type PSType="Microsoft.Management.Infrastructure.CimInstance[]" />
<CmdletOutputMetadata />
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Get-StdRegProvChildValue: invoking method EnumValues():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Get" Noun="WmiStdRegProvChildValue" ConfirmImpact="High" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="EnumValues">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubkeyName'-->
<Parameter ParameterName="SubkeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--Method returns an instance of string in property sNames-->
<Parameter ParameterName="sNames">
<Type PSType="Microsoft.Management.Infrastructure.CimInstance[]" />
<CmdletOutputMetadata />
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Get-StdRegProvBinary: invoking method GetBinaryValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Get" Noun="WmiStdRegProvBinary" ConfirmImpact="Low" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="GetBinaryValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--Method returns an instance of uint8 in property uValue-->
<Parameter ParameterName="uValue">
<Type PSType="Microsoft.Management.Infrastructure.CimInstance[]" />
<CmdletOutputMetadata />
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Get-StdRegProvDword: invoking method GetDWORDValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Get" Noun="WmiStdRegProvDword" ConfirmImpact="Low" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="GetDWORDValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--Method returns an instance of uint32 in property uValue-->
<Parameter ParameterName="uValue">
<Type PSType="Microsoft.Management.Infrastructure.CimInstance[]" />
<CmdletOutputMetadata />
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Get-StdRegProvExpandedString: invoking method GetExpandedStringValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Get" Noun="WmiStdRegProvExpandedString" ConfirmImpact="Low" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="GetExpandedStringValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--Method returns an instance of string in property sValue-->
<Parameter ParameterName="sValue">
<Type PSType="Microsoft.Management.Infrastructure.CimInstance[]" />
<CmdletOutputMetadata />
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Get-StdRegProvMultiString: invoking method GetMultiStringValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Get" Noun="WmiStdRegProvMultiString" ConfirmImpact="Low" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="GetMultiStringValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--Method returns an instance of string in property sValue-->
<Parameter ParameterName="sValue">
<Type PSType="Microsoft.Management.Infrastructure.CimInstance[]" />
<CmdletOutputMetadata />
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Get-StdRegProvQWord: invoking method GetQWORDValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Get" Noun="WmiStdRegProvQWord" ConfirmImpact="Low" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="GetQWORDValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--Method returns an instance of uint64 in property uValue-->
<Parameter ParameterName="uValue">
<Type PSType="Microsoft.Management.Infrastructure.CimInstance[]" />
<CmdletOutputMetadata />
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Get-StdRegProvSecurityDescriptor: invoking method GetSecurityDescriptor():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Get" Noun="WmiStdRegProvSecurityDescriptor" ConfirmImpact="Low" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="GetSecurityDescriptor">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--Method returns an instance of __SecurityDescriptor in property Descriptor-->
<Parameter ParameterName="Descriptor">
<Type PSType="Microsoft.Management.Infrastructure.CimInstance[]" />
<CmdletOutputMetadata />
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Get-StdRegProvString: invoking method GetStringValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Get" Noun="WmiStdRegProvString" ConfirmImpact="Low" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="GetStringValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'StringValue'-->
<Parameter ParameterName="StringValue">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="3" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--Method returns an instance of string in property sValue-->
<Parameter ParameterName="sValue">
<Type PSType="Microsoft.Management.Infrastructure.CimInstance[]" />
<CmdletOutputMetadata />
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Set-StdRegProvBinary: invoking method SetBinaryValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Set" Noun="WmiStdRegProvBinary" ConfirmImpact="Medium" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="SetBinaryValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ByteValue'-->
<Parameter ParameterName="ByteValue">
<!--the underlying parameter type is uint8 which corresponds to the PowerShell .NET type [byte]-->
<Type PSType="byte" />
<CmdletParameterMetadata Position="3" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Set-StdRegProvDword: invoking method SetDWORDValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Set" Noun="WmiStdRegProvDword" ConfirmImpact="Medium" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="SetDWORDValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'IntValue'-->
<Parameter ParameterName="IntValue">
<!--the underlying parameter type is uint32 which corresponds to the PowerShell .NET type [system.uint32]-->
<Type PSType="system.uint32" />
<CmdletParameterMetadata Position="3" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Set-StdRegProvExpandedString: invoking method SetExpandedStringValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Set" Noun="WmiStdRegProvExpandedString" ConfirmImpact="Medium" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="SetExpandedStringValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'StringValue'-->
<Parameter ParameterName="StringValue">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="3" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Set-StdRegProvMultiString: invoking method SetMultiStringValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Set" Noun="WmiStdRegProvMultiString" ConfirmImpact="Medium" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="SetMultiStringValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'StringArrayValue'-->
<Parameter ParameterName="StringArrayValue">
<!--the underlying parameter type is object which corresponds to the PowerShell .NET type [system.object]-->
<Type PSType="system.object" />
<CmdletParameterMetadata Position="3" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Set-StdRegProvQWord: invoking method SetQWORDValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Set" Noun="WmiStdRegProvQWord" ConfirmImpact="Medium" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="SetQWORDValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'Int64Value'-->
<Parameter ParameterName="Int64Value">
<!--the underlying parameter type is uint64 which corresponds to the PowerShell .NET type [system.uint64]-->
<Type PSType="system.uint64" />
<CmdletParameterMetadata Position="3" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Set-StdRegProvSecurityDescriptor: invoking method SetSecurityDescriptor():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Set" Noun="WmiStdRegProvSecurityDescriptor" ConfirmImpact="High" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="SetSecurityDescriptor">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'Descriptor'-->
<Parameter ParameterName="Descriptor">
<!--the underlying parameter type is Win32_SecurityDescriptor which corresponds to the PowerShell .NET type [System.Management.ManagementBaseObject]-->
<Type PSType="System.Management.ManagementBaseObject" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
</Parameters>
</Method>
</Cmdlet>
<!--Set-StdRegProvString: invoking method SetStringValue():-->
<Cmdlet>
<!--defining the ConfirmImpact which indicates how severe the changes are that this cmdlet performs-->
<CmdletMetadata Verb="Set" Noun="WmiStdRegProvString" ConfirmImpact="Medium" />
<!--defining the WMI instance method used by this cmdlet:-->
<Method MethodName="SetStringValue">
<ReturnValue>
<Type PSType="system.uint32" />
<CmdletOutputMetadata>
<ErrorCode />
</CmdletOutputMetadata>
</ReturnValue>
<!--defining the parameters of this cmdlet:-->
<Parameters>
<!--native parameter name is 'Hive'-->
<Parameter ParameterName="Hive">
<!--the underlying parameter type is Hive which really is the enumeration [StdRegProv.Hive] that is defined below in the Enums node:-->
<Type PSType="StdRegProv.Hive" />
<CmdletParameterMetadata Position="0" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'SubKeyName'-->
<Parameter ParameterName="SubKeyName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="1" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'ValueName'-->
<Parameter ParameterName="ValueName">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="2" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
<!--native parameter name is 'StringValue'-->
<Parameter ParameterName="StringValue">
<!--the underlying parameter type is string which corresponds to the PowerShell .NET type [system.string]-->
<Type PSType="system.string" />
<CmdletParameterMetadata Position="3" IsMandatory="false">
<ValidateNotNull />
<ValidateNotNullOrEmpty />
</CmdletParameterMetadata>
</Parameter>
</Parameters>
</Method>
</Cmdlet>
</StaticCmdlets>
</Class>
</PowerShellMetadata>
'@ | Set-Content -LiteralPath $cdxmlPath -Encoding UTF8
# import module
Import-Module -Name $cdxmlPath -Force -Verbose
# list new cmdlets
Get-Command -Module "StdRegProv"
See here for more information on CDXML and CDXML-based PowerShell modules.
Requirements
To use StdRegProv, the following requirements apply:
PowerShell
Get-CimInstance
was introduced with PowerShell Version 3.0, which in turn was introduced on clients with Windows 8 and on servers with Windows Server 2012.
If necessary, update Windows PowerShell to Windows PowerShell 5.1, or install PowerShell 7 side-by-side.
Operating System
StdRegProv was introduced on clients with Windows Vista and on servers with Windows Server 2008.
Namespace
StdRegProv lives in the namespace root/default, root/cimv2. This is not the default namespace. Use parameter -Namespace root/default, root/cimv2 with all CIM cmdlets..
Implementation
StdRegProv is implemented in Stdprov.dll and defined in RegEvent.mof. Both files are located in the folder C:\Windows\system32\wbem
:
explorer $env:windir\system32\wbem
notepad $env:windir\system32\wbem\RegEvent.mof